package ${packageName}.domain;

import lombok.*;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.powerpms.common.annotation.Aggregation;
import com.powerpms.common.annotation.ToMany;
import com.powerpms.common.annotation.ToMaster;
import com.powerpms.common.domain.BaseEntity;
import com.powerpms.common.type.Dict;
import com.puhua.pms.server.pm.communicate.mapper.CoStaGroupVsUserMapper;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;

@Data
@Aggregation(
master = @ToMaster(show = false)
,one = {
}
,many = {
}
)
@TableName("${tableName}")
@Schema(description = "")
public class ${className} extends BaseEntity${r"<Long>"} {
    <#-- 定义需要排除的字段列表 -->
    <#assign excludedFields = ["code", "name", "add_id", "add_name", "add_time",
    "update_id", "update_name", "update_time", "status", "sequ", "id"]>

    <#list columns as column>
        <#-- 检查字段是否在排除列表中 -->
        <#if !excludedFields?seq_contains(column.name)>
            <#if column.remarks?? && column.remarks != "">
                /** ${column.remarks} */
            </#if>
            @TableField(value = "${column.name}")
            @JsonProperty("${column.javaName}") @Schema(description = "${column.remarks}")
            private ${column.javaType} ${column.javaName};
        </#if>
    </#list>
}